<template>
  <div class="footer">
    <div class="f-container">
      <div class="callMe flex-center">
        <h4>联系我呀</h4>
        <img src="../assets/img/index/head-icon.jpg" />
      </div>
      <div class="flex-center">
        <h4>技术支持</h4>
        <div class="flex-center">
          <a
            v-for="(item, index) in skillSupport"
            :href="item.link"
            target="_blank"
            :alt="item.name"
            >{{ item.name }}</a
          >
        </div>
      </div>
      <div class="flex-center">
        <h4>学习网站</h4>
        <div class="flex-center">
          <a
            v-for="(item, index) in linkList"
            :href="item.link"
            target="_blank"
            :alt="item.name"
            >{{ item.name }}</a
          >
        </div>
      </div>
    </div>
    <div class="last">
      <span class="ttl">
        网站已运行: <span id="webRuntime">1年336天19时37分37秒</span>
      </span>
      <br />
      <span class="copyRight">
        Copyright © 2020-Now CY All Rights Reserved.
      </span>
    </div>
  </div>
</template>

<script>
export default {
  name: 'Footer',
  data() {
    return {
      skillSupport: [
        { name: 'Semantic UI', link: 'https://semantic-ui.com' },
        { name: 'Spring', link: 'https://spring.io/' },
        { name: 'Redis', link: 'https://redis.io/' },
        { name: 'Mybatis', link: 'https://mybatis.org/mybatis-3/' },
        { name: 'Jquery', link: 'https://jquery.cuishifeng.cn/' },
        { name: 'Vue', link: 'https://cn.vuejs.org/' },
      ],
      linkList: [
        { name: 'Github', link: 'https://semantic-ui.com' },
        { name: 'BiliBili', link: 'https://www.bilibili.com' },
        { name: 'Gitee', link: 'https://gitee.com/' },
        { name: 'W3Cschool', link: 'https://www.w3cschool.cn/' },
        { name: 'CSDN', link: 'https://www.csdn.net/' },
        { name: '稀土掘金', link: 'https://juejin.cn/' },
        { name: '语雀', link: 'https://www.yuque.com/' },
      ],
    }
  },
}
</script>

<style lang="scss">
.footer {
  width: 100%;
  min-height: 300px;
  background-color: var(--footer-bg);
  color: var(--footer-color);
  padding-top: 20px;
  > .f-container {
    width: 80%;
    margin: 0 auto;
    display: flex;
    justify-content: space-evenly;
    > .callMe {
      > h4 {
        font-weight: bold;
      }
      > img {
        width: 150px;
        border-radius: 10px;
      }
    }
  }
  h4 {
    margin-bottom: 10px;
  }
  a {
    color: var(--footer-color);
    transition: 0.3s;
    margin-bottom: 4px;
    &:hover {
      color: aqua;
    }
  }
  > .last {
    margin: 0 auto;
    text-align: center;
  }
}
.flex-center {
  display: flex;
  flex-direction: column;
  align-items: center;
}
</style>
